# -*- coding:utf-8 -*-
"""
@File       :   二叉树后序遍历.py
@Author     :   LINING
@Time       :   2024/1/18 11:24
@Description :   
"""

class Node():
    def __init__(self, value=0, left=None, right=None):
        self.value = value
        self.left = left
        self.right = right


node = Node(1)
node1 = Node(2)
node2 = Node(3, node1, node)

result = []


def Traversal(node):
    """
    node:当前遍历的节点
    """
    if node is None:
        return
    Traversal(node.left)
    Traversal(node.right)
    result.append(node.value)


Traversal(node2)
print(result)
